package com.train.mapper;

import com.train.dto.CourseDTO;
import com.train.pojo.Course;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
import org.springframework.stereotype.Repository;

import java.util.List;

@Mapper
@Repository
public interface CourseMapper {

    List<CourseDTO> selectAllCourseDTO();

    List<CourseDTO> findByRequired(CourseDTO courseDTO);

    List<Course> getCourseBydepid(@Param("id")Integer id);

    Course selectCourseById(@Param("id")Integer id);

    int addCourse(Course course);

    int updateCourse(Course course);

    int deleteCourse(@Param("id") Integer id);
}
